package com.zpb.framework.exception;

import com.zpb.framework.domain.enums.ResultCodeEnum;
import lombok.Getter;

/**
 * @Description:
 * @Author: zhaopengbo
 * @Date: 2025/9/11
 */
@Getter
public class SystemException extends RuntimeException {
    private Integer code;
    private String msg;
    public SystemException(ResultCodeEnum resultCodeEnum) {
        super(resultCodeEnum.getMsg());
        this.code = resultCodeEnum.getCode();
        this.msg = resultCodeEnum.getMsg();
    }
    public SystemException(Integer code, String msg) {
        super(msg);
        this.code = code;
        this.msg = msg;
    }
}
